<template>
  <div class="contactUs">
    <div class="banner">
      <div>
        <p>联系我们</p>
        <p class="info">您可以通过一下方式联系我们</p>
      </div>
    </div>
    <div class="contactMain">
      <div class="desc">
        狸花工坊，隶属于成都指针飞渡数字科技有限公司，致力于RPA机器人研发，目前已覆盖电商，直播，游戏等行业。我们通过RPA机器人给每一位客户定做最优的机器人流程自动化解决方案，将各类型顾客的业务流程通过机器人进行自动化操作，从而帮助顾客提高工作效率和准确率，并且降低其成本
      </div>
      <div class="contact">
        <div
          class="contactItem"
          v-for="(item, index) in contactItems"
          :key="index"
        >
          <img :src="item.imgUrl1" alt="" />
          <p>{{ item.name1 }}</p>
          <div class="contactList">
            <div v-for="(items, index) in item.depict">
              <span class="dot"></span>
              <span>
                {{ items.txt }}
              </span>
            </div>
          </div>
          <div class="contact-qrcode">
            <img :src="item.imgUrl2" alt="" />
            <p>
              {{ item.name2 }}
            </p>
          </div>
        </div>
      </div>
      <baidu-map
        class="map"
        :center="{ lng: 104.195966, lat: 30.580445 }"
        :zoom="18"
        :scroll-wheel-zoom="true"
      >
        <bm-marker
          :position="{ lng: 104.195966, lat: 30.580445 }"
          @click="infoWindowOpen"
        >
          <bm-info-window
            :show="show"
            @close="infoWindowClose"
            @open="infoWindowOpen"
            >成都指针飞渡数字科技有限公司
            <br />
            地址：成都市龙泉驿区大面街道金槐街158号21栋1层5号
          </bm-info-window></bm-marker
        >
      </baidu-map>
    </div>
  </div>
</template>

<script>
export default {
  name: "Contact",
  data() {
    return {
      show: true,
      contactItems: [
        {
          name1: "QQ",
          name2: "机器人售前微信",
          imgUrl1: require("@/static/qq.png"),
          imgUrl2: require("@/static/erweima.png"),
          depict: [
            { txt: "客服QQ:800181501" },
            { txt: "或者点击右下角在线咨询" },
          ],
        },
        {
          name1: "邮箱",
          name2: "商务合作微信",
          imgUrl1: require("@/static/qq.png"),
          imgUrl2: require("@/static/erweima.png"),
          depict: [{ txt: "business@team.com" }],
        },
        {
          name1: "电话",
          name2: "官方公众号",
          imgUrl1: require("@/static/qq.png"),
          imgUrl2: require("@/static/erweima.png"),
          depict: [
            { txt: "售前电话:17102890879" },
            { txt: "售后紧急联系电话:17742890672" },
          ],
        },
      ],
    };
  },
  methods: {
    infoWindowClose() {
      this.show = false;
    },
    infoWindowOpen() {
      this.show = true;
    },
  },
};
</script>

<style lang="less" scoped>
.contactUs {
  width: 100%;
  min-height: 100vh;
  background: #f5f5f5;
  .banner {
    width: 100%;
    height: 372px;
    background-color: #2e2f3a;
    background-image: url(../static/contactUs.png);
    background-repeat: no-repeat;
    background-size: cover;
    display: flex;
    align-items: center;
    justify-content: center;
    > div {
      font-size: 14px;
      font-family: Microsoft YaHei;
      font-weight: 400;
      color: #fff;
      text-align: center;
      > p {
        font-size: 40px;
        font-family: Microsoft YaHei;
        font-weight: 700;
        color: #fff;
        margin-bottom: 35px;
      }
      .info {
        font-size: 14px;
        font-family: Microsoft YaHei;
        font-weight: 400;
        color: #fff;
        text-align: center;
        width: 365px;
      }
    }
  }
  .contactMain {
    width: 1200px;
    margin: 0 auto;
    box-sizing: border-box;
    padding-bottom: 83px;
    .desc {
      margin: 72px auto 0;
      width: 1017px;
      font-size: 16px;
      font-family: "PingFang SC";
      font-weight: 400;
      color: #222;
      line-height: 30px;
    }
    .contact {
      margin: 58px auto 0;
      width: 1017px;
      display: flex;
      justify-content: space-between;
      .contactItem {
        display: flex;
        flex-direction: column;
        align-items: center;
        font-size: 20px;
        font-family: PingFang SC;
        font-weight: 700;
        color: #222;
        img {
          width: 116px;
          height: 116px;
          margin-bottom: 14px;
        }
        .contactList {
          margin-top: 27px;
          height: 100px;
          font-size: 16px;
          font-family: PingFang SC;
          font-weight: 400;
          color: #222;
          > div {
            display: flex;
            align-items: center;
            line-height: 30px;
            .dot {
              width: 7px;
              height: 7px;
              background: #298df8;
              box-shadow: 0 3px 5px 0 rgb(84 152 255 / 89%);
              margin-right: 7px;
              transform: rotate(45deg);
            }
          }
        }
        .contact-qrcode {
          display: flex;
          flex-direction: column;
          align-items: center;
          margin-top: 35px;
          font-size: 14px;
          font-family: Microsoft YaHei;
          font-weight: 400;
          color: #787878;
          img {
            width: 100px;
            height: 100px;
          }
        }
      }
    }
    .map {
      width: 100%;
      height: 450px;
      margin: 67px 0 0;
    }
  }
}
</style>